package com.atguigu.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.Entity;
import javax.persistence.Table;

//购物车项
@Data
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "t_cart")
@Entity
public class CartItem  {
    private Integer id ;
    private Book book ;     //M:1
    private String bookName ;
    private Double price ;
    private Integer buyCount ;
    private User user ;     //当前购物车项属于哪个用户   M:1
 }
